<?php
/**
 * Created by PhpStorm.
 * User: zhangrxiang
 * Date: 2017/11/1
 * Time: 11:22
 */


$facilities = array(
	LOG_AUTH,
	LOG_AUTHPRIV,
	LOG_CRON,
	LOG_DAEMON,
	LOG_KERN,
	LOG_LOCAL0,
	LOG_LPR,
	LOG_MAIL,
	LOG_NEWS,
	LOG_SYSLOG,
	LOG_USER,
	LOG_UUCP,
);

for ($i = 0; $i < 10000; $i++) {
	foreach ($facilities as $facility) {
		openlog('test', LOG_PID, $facility);
		syslog(LOG_ERR, "This is a test: " . memory_get_usage(true));
	}
}